\documentclass[a4paper,11pt,twoside]{book}

\input{preamble}          % configurations

\begin{document}

    \frontmatter

    \include{title}       % include title page

\addcontentsline{toc}{chapter}{Contents}
\pagenumbering{roman}
\tableofcontents

    \include{preface}     % include preface
    \include{license}     % include other frontmatter

    \mainmatter

    \input{main}          % include chapter list

    %\appendix
    %\include{history}

    %\backmatter

    %\include{bibliography}  % include bibliography
    %\include{index}         % include index

\end{document}
